Migrate build to IntelliJ Platform Gradle Plugin 2.x (Gradle 9, IDE 2026.1)#36
Merged
Merged
Conversation
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The org.jetbrains.intellij 1.x plugin is EOL: it uses Gradle-internal API removed in Gradle 9 and cannot build against IDE targets >= 2024.2. Replace it with org.jetbrains.intellij.platform 2.x using the unified intellijIdea distribution (IC is no longer published since 2025.3), raise the Java target to 21 as required by modern IDE targets, and declare sinceBuild 261. Ignore the plugin's .intellijPlatform cache dir. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Lombok 1.18.34 crashes javac 25 with ExceptionInInitializerError during compileTestJava. A toolchain makes Gradle compile with a discovered JDK 21 regardless of the JVM that launches the build. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
- IntelliJ Platform Gradle Plugin 2.11.0 -> 2.18.1 - JUnit Jupiter/Platform 5.10.3/1.10.3 -> 6.1.2 (unified versioning) - Hamcrest 2.2 -> 3.0 - Lombok 1.18.34 -> 1.18.46 (adds JDK 25 javac support) - Replace toolchain pin with source/target compatibility 21 so the build runs on the default JDK 25 while emitting Java 21 bytecode Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Improve Git Auto Prefix handling: tie message bus to commit UI, avoid focus issues
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
./gradlew buildwas broken after upgrading the toolchain:org.jetbrains.intellij1.x (every version, incl. 1.17.4) depends on a Gradle-internal class (DefaultArtifactPublicationSet) that Gradle 9 removed, and 1.x also cannot build against IDE targets ≥ 2024.2. This PR completes the upgrade by migrating to JetBrains' successor plugin.Gradle wrapper 9.6.1 (first commit)
gradlew/gradlew.batscripts regenerated via./gradlew wrapperso they match the 9.6.1 properties file (the manual properties-only edit had left them at 8.4).Build migration (second commit)
org.jetbrains.intellij1.17.4 →org.jetbrains.intellij.platform2.11.0dependencies { intellijPlatform { ... } }block using the unifiedintellijIdea '2026.1.4'distribution (IC is no longer published since 2025.3) +bundledPlugin 'Git4Idea'patchPluginXml/runPluginVerifierblocks replaced byintellijPlatform { pluginConfiguration { ideaVersion { sinceBuild = '261' } } }andpluginVerification { ides { recommended() } }.intellijPlatformcache dir gitignoredCompatibility note:
sinceBuild = 261means users on IDEs older than 2026.1 stop receiving updates (intentional).Kotlin DSL migration
build.gradle/settings.gradleconverted tobuild.gradle.kts/settings.gradle.kts(1:1, no behavior change). The IntelliJ Platform Gradle Plugin 2.x DSL is Kotlin-based, so the Groovy scripts produced unresolvable-method warnings in the IDE; with Kotlin DSL the editor resolves everything cleanly.Bugfix: focus stolen on branch change — Fixes #37
CommitPrefixCheckinHandlerno longer callsCheckinProjectPanel.setCommitMessage(...)when aCommitMessagecomponent is available: in the non-modal commit UI that call unconditionally focuses the commit editor (CommitProjectPanelAdapter.setCommitMessage→commitMessageUi.focus()), stealing focus from the terminal on every branch switch. The message is now set via the non-focusingCommitMessage.setText(...).GIT_REPO_CHANGEmessage bus subscription is now tied to the commit UI's lifecycle (parentDisposable), so stale handlers no longer accumulate and re-fire.Test plan
./gradlew build— compiles, all 133 tests pass on Gradle 9.6.1 / JDK 21./gradlew buildPlugin— producescommit-prefix-plugin-1.4.2.zip./gradlew verifyPlugin— Compatible against IU-261.26222.65 (2026.1) and IU-262.8665.176 (2026.2 EAP), dynamic-plugin eligiblerunIde: branch switch in the terminal updates the prefix without stealing focus (non-modal UI)🤖 Generated with Claude Code